﻿using System;
using System.Collections;
using System.ComponentModel;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Services;
using System.Web.Services.Protocols;
using System.Xml.Linq;
using BLL;
namespace DBLWebService
{
    /// <summary>
    /// UserPersonService 的摘要说明
    /// </summary>
    [WebService(Namespace = "http://tempuri.org/")]
    [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
    [ToolboxItem(false)]
    // 若要允许使用 ASP.NET AJAX 从脚本中调用此 Web 服务，请取消对下行的注释。
    // [System.Web.Script.Services.ScriptService]
    public class UserPersonService : System.Web.Services.WebService
    {

        //[WebMethod]
        //public string HelloWorld()
        //{
        //    return "Hello World";
        //}

        [WebMethod(Description = "根据id获得个人的详细信息")]
        public DataSet FindPersonDetailByID(string id)
        {
            return UserPersonBLL.FindPersonDetailByID(id);
        }


        [WebMethod(Description = "增加或者更新个人详细信息")]
        public int AddUpdateUserPerson(int id, string dblNo, string nickName,
          string fullName, string keyWord1, string keyWord2, string keyWord3, string shenfenzheng,
              string address, string description, string phone, string fax,
                  string email, string mobilePhone, string qq, string msn,
                      string blog, string weibo, string website)
        {
            return UserPersonBLL.AddUpdateUserPerson(id, dblNo, nickName, fullName, keyWord1, keyWord2, keyWord3, shenfenzheng,
                address, description, phone, fax, email, mobilePhone, qq, msn, blog, weibo, website);
        }

        [WebMethod(Description = "个人用户信息审核通过")]
        public int ApproveUserPerson(int id)
        {
            return UserPersonBLL.ApproveUserPerson(id);
        }

        [WebMethod(Description = "个人用户信息审核不通过")]
        public int NotApproveUserPerson(int id)
        {
            return UserPersonBLL.NotApproveUserPerson(id);
        }
    }
}
